/*
 * Copyright 2013 Agustina Martinez-Garcia

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
 */
package uk.ljmu.mulgaraifz.httprequests;

import java.util.HashMap;
import java.util.List;

import org.igfay.jfig.JFigException;

import uk.ljmu.mulgaraifz.errorhandling.MulgaraException;
import uk.ljmu.mulgaraifz.model.CollectionNode;
import uk.ljmu.mulgaraifz.model.DublinCore;
import uk.ljmu.mulgaraifz.httprequests.HttpManagement;

public interface MulgaraOperations {
	public boolean isMulgaraRunning();
	public List<String> getRootCollections() throws MulgaraException;
	public List<String> getRootCollectionsTitle() throws MulgaraException;
	public DublinCore getCollectionInfo(String identifier) throws MulgaraException;
	public void getResourcesInfo(String colIdentifier) throws MulgaraException;
	public HashMap<String, DublinCore> getResourceInfo();
	public List<String> getCollectionChildren(String colIdentifier) 
	throws MulgaraException;
	public List<String> getCollectionChildrenTitle(String colIdentifier)
	throws MulgaraException;
	public List<String> getRecentCollections(String currentDate) throws MulgaraException;
	public List<String> getRecentCollectionsTitle(String currentDate) throws MulgaraException;
	public List<String> getRecentResources(String identifier) throws MulgaraException;
	public List<String> getObjectsTitles(String namespace) throws MulgaraException;
	public void callRecursiveCollectionsTree(List<String> collectionsIDs) throws MulgaraException;
	public void callRecursiveCollectionsTreeNoChildren(List<String> collectionsIDs) 
	throws MulgaraException;
	public void callRecursiveCollectionsTreeNoChildrenQudex(
		    List<String> collectionsIDs) throws MulgaraException;
	public void resetTree();
	public String getNumberOfChildrenTQL(String collectionIdentifier) 
	throws MulgaraException, JFigException;
	public List<String> getCollections(String query) throws MulgaraException;
	public List<CollectionNode> getTreeList();
	public void initTree();
	public HttpManagement getHttpMan();
	public void mulgaraFinaliseHttpConnections();
}
